import Vue from "vue";
import App from "./App.vue";
import router from "./router";
import store from "./store";

import Vant from "vant";
import "vant/lib/index.css";

Vue.use(Vant);
Vue.config.productionTip = false;

// 引入样式
import "./assets/css/reset.css";
// 引入网络请求
import * as api from "./sever/api.js"
Vue.prototype.$api=api

import "./components/index"

import * as utils from "./utils/dounce"
Vue.prototype.$utils = utils

import Router from 'vue-router';
Vue.use(Router);
const originalPush = Router.prototype.push
Router.prototype.push = function push(location) {
  return originalPush.call(this, location).catch(err => err)
}

new Vue({
  router,
  store,
  render: (h) => h(App),
}).$mount("#app");
